@import "../../vendor/bootstrap/variables";
@import "../../vendor/simple-line-icons";
@import "../../vendor/sweetalert";
@import "../includes/sweetalert";
// bootstrap datetimepicker
@import "../../vendor/bootstrap-datetimepicker";
@import "../includes/select2-variables";
@import "../../vendor/select2";

html, body, button, input, select, textarea {
	-webkit-font-smoothing: antialiased;

	// 从全局角度, 允许从单词中间折行, :'(
	-ms-word-break: break-all;
	word-break: break-all;

	// Non standard for webkit
	word-break: break-word;
}

// remove global scrollbar
::-webkit-scrollbar {
	//height: 10px;
	width: 0;
	//overflow: visible;
}

/* here you can put your own css to customize and override the theme */
.page-header.navbar {
	.page-logo {
		line-height: 50px;
		a {
			color: #eee;
		}
	}
}

.page-container {
	margin-top: 50px;
}

// create some empty boxes to push elements away from each other
@for $i from 1 through 20 {
	.vertical-push-#{$i}0 {
		height: #{$i}0px;
	}
}

// remove the fixed width of the user dropdown menu on the top navbar
.page-header.navbar .top-menu .navbar-nav > li.dropdown-user > .dropdown-menu {
	width: auto;
	min-width: 0;
}

// remove checkbox offset
.radio input[type="radio"], .radio-inline input[type="radio"], .checkbox input[type="checkbox"], .checkbox-inline input[type="checkbox"] {
	/* position: absolute; */
	/* margin-left: -20px; */
	position: relative;
	margin-left: 0;
	margin-top: 4px \9
;
}

// file input beautification
.file {
	position: relative;
	display: inline-block;
	height: 34px;
	cursor: pointer;
	width: 100%;
	margin-top: 5px;
	border-radius: 4px;
	.error {
		color: $alert-danger-text;
	}
	input[type="file"] {
		display: block;
		margin: 0;
		filter: alpha(opacity=0);
		opacity: 0;
	}
	span {
		display: block;
		position: absolute;
		top: 0;
		right: 0;
		left: 0;
		bottom: 0;
		z-index: 5;
		padding: 0 10px;
		line-height: 32px;
		color: #555;
		user-select: none;
		background-color: #fff;
		border: 1px solid #c2cad8;
		//border-radius: 4px;
		box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
		&:before {
			position: absolute;
			top: 0;
			right: 0;
			bottom: 0;
			z-index: 2;
			display: block;
			padding: 0 20px;
			line-height: 32px;
			color: #555;
			content: "选择文件";
			background-color: #eee;
			border-left: 1px solid #c2cad8;
			//border-radius: 0 4px 4px 0;
		}
		&:after {
			font-weight: normal;
			color: #888;
			font-size: .9em;
			content: "未选择文件";
		}
	}
	&[disabled] {
		span {
			background-color: #eee;
			&:before, &:after {
				color: #888;
			}
		}
	}
}

// clickable state table row which has a has-show-view class
.has-show-view {
	tr {
		cursor: pointer;
	}
}

// remove the right margin of the last button
* {
	.btn:last-child {
		margin-right: 0;
	}
}

// center table content
table {
	th {
		text-align: center;
	}
	th, td {
		vertical-align: middle !important;
	}
}

.a-unstyled {
	vertical-align: middle;
	&:hover, &:focus {
		text-decoration: none;
	}
}

//select {
//	-webkit-appearance: none;
//	border-radius: 0;
//}

// form front-end error text style
.form-group {
	& > .error {
		color: $state-danger-text;
	}
	&.has-error {
		.ignore {
			border: 1px solid #ccc;
			&:focus {
				border-color: #66afe9;
				outline: 0;
				box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(102, 175, 233, 0.6);
			}
		}
	}
}

// tweak rich text editor style a little
[data-rich-text-editor] {
	width: 100%;
	height: 320px;
	margin-bottom: 50px;
}

// remove hove bg for some tds
.table-hover > tbody > tr:hover > td[rowspan="2"] {
	background: #fbfcfd !important;
}

// fouc patch
.fouc {
	opacity: 0 !important;
}

.btn-submit,
.btn-save {
	opacity: 0;
}

.fouc-editor {
	opacity: 0 !important;
}

// increase page-content min-height
.page-content-wrapper .page-content {
	min-height: 100%;
}

// make sidebar and content scroll separately
html,
body {
	height: 100%;
}

.page-container {
	height: 100%;
	overflow: hidden;
	margin-top: 0;
	padding-top: 50px;
	.page-sidebar-wrapper {
		overflow: hidden;
		height: 100%;
		float: left;
		.page-sidebar {
			height: 100%;
			overflow: auto;
			ul {
				height: 100%;
			}
		}
	}
	.page-content-wrapper {
		float: none;
		width: auto;
		height: 100%;
		overflow: auto;
		.page-content {
			margin-left: 0;
		}
	}
}

// dragula
.gu-mirror {
	position: fixed !important;
	margin: 0 !important;
	z-index: 9999 !important;
	opacity: .8;
	-ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=80)";
	filter: alpha(opacity=80)
}

.gu-hide {
	display: none !important
}

.gu-unselectable {
	-webkit-user-select: none !important;
	-moz-user-select: none !important;
	-ms-user-select: none !important;
	user-select: none !important
}

.gu-transit {
	opacity: .2;
	-ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=20)";
	filter: alpha(opacity=20)
}

// sortable items
.has-sortable-items {
	& > label {
		margin-left: 0;
		margin-right: 5px;
	}
}

// tooltip inner width
.tooltip-inner {
	max-width: none;
	white-space: nowrap;
}






